package cn.tedu.travelsystem.travelDownload.service;

import lombok.Getter;
import lombok.Setter;

@Getter @Setter
public class Result {
    private int code;
    private String message;
    private Object data;

    public static Result success(Object data) {
        Result result = new Result();
        result.code = 200;
        result.message = "success";
        result.data = data;
        return result;
    }

    public static Result error(String message) {
        Result result = new Result();
        result.code = 500;
        result.message = message;
        return result;
    }
}